﻿
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<!-- saved from url=(0014)about:internet -->
<html xmlns:msxsl="urn:schemas-microsoft-com:xslt" xmlns:mssdk="winsdk" xmlns:script="urn:script" xmlns:build="urn:build" xmlns:MSHelp="http://msdn.microsoft.com/mshelp">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<meta name="Description" content="Creating Your Own Provider Module"/>
<meta name="MSHAttr" content="PreferredSiteName:MSDN"/>
<meta name="MSHAttr" content="PreferredLib:/library/windows/hardware"/>
<title>Creating Your Own Provider Module</title>

<meta name="MS-HAID" content="SymChk_e3c8ede7-4e43-4f37-87bb-136cefd26814.xml"/>


<link rel="STYLESHEET" type="text/css" HREF="../common/backsdk4.css"/>





<style>
html,div { margin: 0; padding: 0;}

body {
	padding: 0px;
	margin: 0px;
	overflow: auto;
	height: 100%;
}

#winchm_template_button{
	float: right;
	width: 93px;
	top: 7px;
	position: relative;
	text-align: right;
	right: 5px;
	height: auto;
}

#winchm_template_top{
	padding: 0px;
	margin: 0px;
	border-bottom: 1px solid #9B9B9B;
	background-color: #B1CEFE;
}

#winchm_template_navigation{
	margin: 0px;
	padding-top: 7px;
	padding-left: 7px;
	padding-bottom: 3px;
	padding-right: 0px;
	font-size: 8.5pt;
	font-family: Arial, Helvetica, sans-serif;
	font-weight: normal;
	color: #585858;
}

#winchm_template_title{
	margin: 0px;
	padding-top: 4px;
	padding-left: 7px;
	padding-bottom: 7px;
	padding-right: 0px;
	font-size: 18px; 
	font-family: Verdana, Geneva, sans-serif;
	color: #363636;
}

#winchm_template_content{
	margin-top: 20px;
	margin-left: 15px;
	margin-bottom: 20px;
	margin-right: 15px;
	width: auto  !important;
	width: 100%;
}

#winchm_template_footer{
	border-width: 1px;
	border-color: #B1CEFE;
	border-top-style: solid;
	margin-top: 15px;
	margin-left: 15px;
	margin-bottom: 20px;
	margin-right: 15px;
	padding-top: 7px;
	padding-left: 0px;
	padding-bottom: 0px;
	padding-right: 0px;
	font-family: arial, helvetica, sans-serif;
	font-size: 8.5pt;
	color: #696969;
	width: auto;
	text-align: left;
}


#winchm_template_container{
	margin: 0px;
	padding: 0px;
	position: static;
	padding-bottom: 3px;
	overflow: auto;
	background-color: #FFFFFF;
}


@media print
{
#winchm_template_container{
	position: static;	
	margin: 0px;
	padding: 5px;
	
	width: auto;
	height: auto;
	overflow: auto;
}
#winchm_template_button{
visibility:hidden;
}
}

#winchm_template_navigation A:link	{text-decoration: none; color:#004080}
#winchm_template_navigation A:visited  {text-decoration: none; color: #004080}
#winchm_template_navigation A:active {text-decoration: none; color: #004080 }
#winchm_template_navigation A:hover {text-decoration: none;color: #0080FF}

A:link	{text-decoration: underline; color:#0033CC}
A:visited  {text-decoration: underline; color: #0033CC}
A:active {text-decoration: underline; color: #0033CC }
A:hover {text-decoration: underline;color: #FF0000;}
</style>
<script type="text/javascript">
function isMobile(){
Agent = window.navigator.userAgent;
if (Agent.indexOf("iPhone")>=1 || Agent.indexOf("iPad")>=1 || Agent.indexOf("iPod")>=1 || Agent.indexOf("Android")>=1){
return true;
}else{
return false;	
}

}
function d_onresize(){
if (window.navigator.userAgent.indexOf("MSIE")>=1){
document.getElementById('winchm_template_container').style.pixelWidth = document.body.offsetWidth - 3;
document.getElementById('winchm_template_container').style.pixelHeight = document.body.offsetHeight - document.getElementById('winchm_template_top').offsetHeight - 4;
}
document.getElementById('winchm_template_container').style.top = document.getElementById('winchm_template_top').offsetHeight + 'px';
}

function d_onbeforeprint(){
document.getElementById('winchm_template_container').style.width = 'auto';
document.getElementById('winchm_template_container').style.height = 'auto';
}

function d_onafterprint(){
d_onresize();
}

if(!isMobile()){

window.onload = d_onresize;
window.onresize = d_onresize;
window.onbeforeprint = d_onbeforeprint;
window.onafterprint = d_onafterprint;

document.write("<style>\n");
document.write("body {overflow: hidden;}\n");
document.write("#winchm_template_container {position: absolute;overflow: auto;top : 0px;right: 0px;bottom: 0px;left: 0px;}\n");
document.write("</style>\n");
}

</script>
</head>
<body><script language="JavaScript" type="text/JavaScript">
function syn(){
if(parent.nav.tree){
 if(parent.nav.tree.loaded){
  parent.nav.tree.selectNode(162);
 }else{
  setTimeout("syn()",500);
}
  }else{
  setTimeout("syn()",500);
  }}
if(parent!=self){
  setTimeout("syn()",100);
}else{
  parent.location.href = "../../index.htm?page=debugger/creating_your_own_provider_module.htm";
}
originalOnload = window.onload;
if(originalOnload==null){
window.onload = function(){parent.contentLoaded = true;};
}else{
window.onload = function(){originalOnload();parent.contentLoaded = true;};
}
</script> 


<div id="winchm_template_top">
	<div id="winchm_template_button"><A href="using_other_source_control_systems.htm" title="Previous topic"><img id="winchm_template_prev" alt="Previous topic" src="../template2/btn_prev_n.gif" border="0"></a><A href="creating_your_own_source_control_system.htm" title="Next topic"><img id="winchm_template_next" alt="Next topic" src="../template2/btn_next_n.gif" border="0"></a></div>
	<div id="winchm_template_navigation">Help &gt; 
<A href="introduction6.htm">Debugging Tools for Windows (WinDbg, KD, CDB, NTSD)</A> &gt; <A href="debugging_resources.htm">Debugging Resources</A> &gt; <A href="source_code.htm">Source Code</A> &gt; <A href="srcsrv.htm">SrcSrv</A> &gt; <A href="source_control_systems.htm">Source Control Systems</A> &gt; <A href="using_other_source_control_systems.htm">Using Other Source Control Systems</A> &gt; </div>
	<div id="winchm_template_title">Creating Your Own Provider Module</div>
</div>
<div id="winchm_template_container">
	<div id="winchm_template_content"><div id="mainSection"><p>In general, to create your own provider module, you must implement the following set of interfaces. </p>
<p></p>
<dl>
<dt><a id="_module__SimpleUsage__"></a><a id="_module__simpleusage__"></a><a id="_MODULE__SIMPLEUSAGE__"></a><b>$module::SimpleUsage()</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="Purpose"></a><a id="purpose"></a><a id="PURPOSE"></a><b>Purpose</b></dt>
<dd>
<p>Displays simple module usage information to STDOUT.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Parameters"></a><a id="parameters"></a><a id="PARAMETERS"></a><b>Parameters</b></dt>
<dd>
<p>None</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Return_Value"></a><a id="return_value"></a><a id="RETURN_VALUE"></a><b>Return Value</b></dt>
<dd>
<p>None</p>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="_module__VerboseUsage__"></a><a id="_module__verboseusage__"></a><a id="_MODULE__VERBOSEUSAGE__"></a><b>$module::VerboseUsage()</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="Purpose"></a><a id="purpose"></a><a id="PURPOSE"></a><b>Purpose</b></dt>
<dd>
<p>Displays in-depth module usage information to STDOUT.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Parameters"></a><a id="parameters"></a><a id="PARAMETERS"></a><b>Parameters</b></dt>
<dd>
<p>None</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Return_Value"></a><a id="return_value"></a><a id="RETURN_VALUE"></a><b>Return Value</b></dt>
<dd>
<p>None</p>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="_objref____module__new__CommandArguments_"></a><a id="_objref____module__new__commandarguments_"></a><a id="_OBJREF____MODULE__NEW__COMMANDARGUMENTS_"></a><b>$objref = $module::new(</b><i>@CommandArguments</i><b>)</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="Purpose"></a><a id="purpose"></a><a id="PURPOSE"></a><b>Purpose</b></dt>
<dd>
<p>Initializes an instance of the provider module.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Parameters"></a><a id="parameters"></a><a id="PARAMETERS"></a><b>Parameters</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="_CommandArguments"></a><a id="_commandarguments"></a><a id="_COMMANDARGUMENTS"></a><i>@CommandArguments</i></dt>
<dd>
<p>All @ARGV arguments that are not recognized by ssindex.cmd as being general arguments.</p>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Return_Value"></a><a id="return_value"></a><a id="RETURN_VALUE"></a><b>Return Value</b></dt>
<dd>
<p>A reference that can be used in later operations.</p>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="_objref-_GatherFileInformation__SourcePath__ServerHashReference_"></a><a id="_objref-_gatherfileinformation__sourcepath__serverhashreference_"></a><a id="_OBJREF-_GATHERFILEINFORMATION__SOURCEPATH__SERVERHASHREFERENCE_"></a><b>$objref-&gt;GatherFileInformation(</b><i>$SourcePath</i><b>,</b><i>$ServerHashReference</i><b>)</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="Purpose"></a><a id="purpose"></a><a id="PURPOSE"></a><b>Purpose</b></dt>
<dd>
<p>Enables the module to gather the required source-indexing information for the directory specified by the <i>$SourcePath</i> parameter.  The module should not assume that this entry is called only once for each object instancebecause SSIndex may call it multiple times for different paths.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Parameters"></a><a id="parameters"></a><a id="PARAMETERS"></a><b>Parameters</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="_SourcePath"></a><a id="_sourcepath"></a><a id="_SOURCEPATH"></a><i>$SourcePath</i></dt>
<dd>
<p>The local directory containing the source to be indexed.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="_ServerHashReference"></a><a id="_serverhashreference"></a><a id="_SERVERHASHREFERENCE"></a><i>$ServerHashReference</i></dt>
<dd>
<p>A reference to a hash containing all of the entries from the specified Srcsrv.ini file.</p>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Return_Value"></a><a id="return_value"></a><a id="RETURN_VALUE"></a><b>Return Value</b></dt>
<dd>
<p>None</p>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="__VariableHashReference__FileEntry_____objref-_GetFileInfo__LocalFile_"></a><a id="__variablehashreference__fileentry_____objref-_getfileinfo__localfile_"></a><a id="__VARIABLEHASHREFERENCE__FILEENTRY_____OBJREF-_GETFILEINFO__LOCALFILE_"></a><b>(</b><i>$VariableHashReference</i><b>,</b><i>$FileEntry</i><b>) = $objref</b>-&gt;<b>GetFileInfo(</b><i>$LocalFile</i><b>)</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="Purpose"></a><a id="purpose"></a><a id="PURPOSE"></a><b>Purpose</b></dt>
<dd>
<p>Provides the necessary information to extract a single, specific file from the source control system.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Parameters"></a><a id="parameters"></a><a id="PARAMETERS"></a><b>Parameters</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="_LocalFile"></a><a id="_localfile"></a><a id="_LOCALFILE"></a><i>$LocalFile</i></dt>
<dd>
<p>A fully qualified file name.</p>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Return_Values"></a><a id="return_values"></a><a id="RETURN_VALUES"></a><b>Return Values</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="_VariableHashReference"></a><a id="_variablehashreference"></a><a id="_VARIABLEHASHREFERENCE"></a><i>$VariableHashReference</i></dt>
<dd>
<p>A hash reference of the variables necessary to interpret the returned <i>$FileEntry</i>.  Ssindex.cmd caches these variables for every source file used by a single debug file to reduce the amount of information written to the source index stream.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="_FileEntry"></a><a id="_fileentry"></a><a id="_FILEENTRY"></a><i>$FileEntry</i></dt>
<dd>
<p>The file entry to be written to the source index stream to allow SrcSrv to extract this file from source control.  The exact format of this line is specific to the source control system.</p>
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="_TextString___objref-_LongName__"></a><a id="_textstring___objref-_longname__"></a><a id="_TEXTSTRING___OBJREF-_LONGNAME__"></a><i>$TextString</i><b>= $objref-&gt;LongName()</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="Purpose"></a><a id="purpose"></a><a id="PURPOSE"></a><b>Purpose</b></dt>
<dd>
<p>Provides a descriptive string to identify the source control system to the end user.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Parameters"></a><a id="parameters"></a><a id="PARAMETERS"></a><b>Parameters</b></dt>
<dd>
<p>None</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Return_Value"></a><a id="return_value"></a><a id="RETURN_VALUE"></a><b>Return Value</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="_TextString"></a><a id="_textstring"></a><a id="_TEXTSTRING"></a><i>$TextString</i></dt>
<dd>
<p>The descriptive name of the source control system.</p>
</dd>
</dl>
</dd>
</dl>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="_StreamVariableLines__objref-_SourceStreamVariables__"></a><a id="_streamvariablelines__objref-_sourcestreamvariables__"></a><a id="_STREAMVARIABLELINES__OBJREF-_SOURCESTREAMVARIABLES__"></a><b>@StreamVariableLines=$objref-&gt;SourceStreamVariables()</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="Purpose"></a><a id="purpose"></a><a id="PURPOSE"></a><b>Purpose</b></dt>
<dd>
<p>Enables the source control system to add source-control-specific variables to the source stream for each debug file.  The sample modules use this method for writing the required EXTRACT_CMD and EXTRACT_TARGET variables.</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Parameters"></a><a id="parameters"></a><a id="PARAMETERS"></a><b>Parameters</b></dt>
<dd>
<p>None</p>
</dd>
</dl>
<p></p>
<dl>
<dt><a id="Return_Value"></a><a id="return_value"></a><a id="RETURN_VALUE"></a><b>Return Value</b></dt>
<dd>
<p></p>
<dl>
<dt><a id="_StreamVariableLines"></a><a id="_streamvariablelines"></a><a id="_STREAMVARIABLELINES"></a><i>@StreamVariableLines</i></dt>
<dd>
<p>The list of entries for the source stream variables.</p></dd></dl></dd></dl></dd></dl></div></div>	
	<div id="winchm_template_footer">Copyright &copy; 2019. All rights 
reserved. (To change the copyright info, just edit it in template.)</div>
</div>

</body>
</html>
